{% extends 'TopxiaAdminBundle:CloudFile:layout.html.twig' %}

{% set menu = 'admin_cloud_file' %}
{% do load_script('cloudfile/manage') %}

{% block stylesheets %}
  {{parent()}}
  <style>
  .batch-item {
      position: absolute;
      left: 6px;
      top: 3px;
      z-index: 101;
  }
</style>
{% endblock %}

{% block main %}

<div class="eduyun-main">
  <div class="page-header clearfix">
    <h1 class="pull-left">云资源</h1>
  </div>
  <form class="form-inline es-materials-manage" id="materials-form">
    {% include 'TopxiaAdminBundle:CloudFile/Form:course-user-search.html.twig' %}
    {% include 'TopxiaAdminBundle:CloudFile/Form:nav.html.twig' %}
    {% include 'TopxiaAdminBundle:CloudFile/Form:tags.html.twig' %}
    {% include 'TopxiaAdminBundle:CloudFile/Form:filter.html.twig' %}
    {% include 'TopxiaAdminBundle:CloudFile/Form:sort.html.twig' %}
    {% include 'TopxiaAdminBundle:CloudFile/Form:batch.html.twig' %}
    {% include 'TopxiaAdminBundle:CloudFile:table.html.twig' %}
  </form>
</div>

<div id="tag-modal" class="modal in" aria-hidden="false" data-backdrop="static" style="display: none;">
  <div class="modal-dialog ">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal"  aria-hidden="true">×</button>
        <h4 class="modal-title">标签设置</h4>
      </div>
      <div class="modal-body">
        <form class="form-horizontal" id="tag-form" action="{{ path('admin_cloud_file_tag_show') }}" method="post" >
          <div class="form-group" id="form">


            <label class="col-md-2 control-label">标签</label>
            <div class="col-md-8 controls">
              <input type="text" id="tags" data-url="{{ path('material_tag_show_match') }}"name="tags" required="required" class="width-full" tabindex="-1" value="" data-explain="{{'用于按标签搜索课程、相关课程的提取等，由网校管理员后台统一管理'|trans}}">
              <div class="help-block">{{'标签来自网校课程标签，由网校管理员统一管理。'|trans}}</div>
            </div>

          </div>
          <input type="hidden" name="_csrf_token" value="{{ csrf_token('site') }}">
          <input id="select-tag-items" name="fileIds" type="hidden" value="">
        </form>
      </div>
      <div class="modal-footer">
        <button type="button" class="btn btn-link" data-dismiss="modal">取消</button>
        <button id="tag-create-btn" data-submiting-text="正在提交" type="submit" class="btn btn-primary" data-toggle="form-submit" data-target="#tag-form ">保存</button>
      </div>
    </div>
  </div>
</div>

{% endblock %}
